package com.jilefojing.web.support;

import javax.servlet.http.HttpServletRequest;

import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.aspectj.lang.annotation.Pointcut;
import org.springframework.beans.factory.annotation.Autowired;

import com.jilefojing.beans.exception.UserContextException;
import com.jilefojing.web.base.BaseWeb;

@Aspect
public class BeforAopSupport extends BaseWeb {
	@Autowired
	private HttpServletRequest request;

	@Pointcut("@annotation(org.springframework.web.bind.annotation.RequestMapping)")
	public void beforPointcut() {

	}

	@Before("beforPointcut()")
	public void befor() {
		try {
			super.getUserContext();
		} catch (UserContextException e) {
			// 可忽略
		}
	}
}
